package com.rimi.mapper;

import com.rimi.bean.Doctor;
import com.rimi.bean.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @author liHaiYang
 * @version V1.0
 * @Description: (用一句话描述该文件做什么)
 * @date 2021/6/16 11:35
 */
public interface UserMapper {

    User findUserByPhoneNumber(String phonenumber);

    User findUserByUserId(Integer id);

    int addUserToSql(User user);

    List<User> showUser();

    int updateUser(User user);

    int deleteUserByUserId(Integer userId);


    int updateUserPasswordByUserId(@Param("userId") Integer userId, @Param("userPassword") String encode);

    int upLoadImg(String filename,Integer userId);

    int addDoctorByUserId(@Param("doctorId") Integer doctorId, @Param("userId") Integer userId);

    List<Doctor> showDoctorByUserId(Integer userId);

    int deleteDoctorBydoctorId(Integer doctorId);

    int registerUer(User user);
}
